package com.woniuxy.dao;


import com.woniuxy.entity.Departments;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface DepartmentsDao {
    //添加科室
    void insertDepartments(Departments departments);

    //删除科室
    void deleteDepartments(String departmentsId);

    //修改科室
    void updateDepartments(Departments departments);

    //分页查询科室信息
    List<Departments> selectDepartments(@Param("departments") Departments departments,
                                        @Param("pageIndex") int pageIndex,
                                        @Param("pageSize") int pageSize);

    //查询总条数
    int selectDepartmentsCount(@Param("departments") Departments departments);

    //查询所有科室的名称
    List<Departments> getAll();

}
